<?php
global $featured_options;
// The Query
$args = array( 'post_type' => 'featuredpost' , 'posts_per_page' => '-1', 'orderby'=>'menu_order' ,'order'=>'ASC');
$the_query = new WP_Query( $args );

// The Loop
$c = 0;
while ( $the_query->have_posts() ) : $the_query->the_post(); 
$meta_f = get_post_meta(get_the_ID(), $featured_options->get_the_id(), TRUE);
if( $meta_f['cb_show_frontpage'] == 1){
?>
	<div class="featured_column <?=($c++%2==1) ? 'right' : 'left' ?>">
		<div class="featured_banner_title"><?php the_title(); ?></div>
		<div>
			<a href="<?php echo cc_decide_link($post->ID); ?>" target="<?php echo cc_get_link_target($post->ID);?>">
				<?php 
					if ( has_post_thumbnail() ) { // check if the post has a Post Thumbnail assigned to it.
					  echo get_the_post_thumbnail($post->ID, 'full' );
					} 
				?>
			</a>
		</div>
	</div>
<?php
}
endwhile;
// Reset Post Data
wp_reset_postdata();
?>
